CREATE EXTERNAL TABLE jms_dwd.dwd_tab_barscan_scan_delete_base_dt(
  `billcode` string COMMENT '单号',
  `packagecode` string COMMENT '包号',
  `scan_type` string COMMENT '扫描类型',
  `scan_time` timestamp COMMENT '原始单号扫描时间',
  `input_time` timestamp COMMENT '原始单号落库时间',
  `upload_time` timestamp COMMENT '上传时间',
  `delete_time` timestamp COMMENT '删除时间',
  `delete_site_id` bigint COMMENT '删除网点id',
  `delete_site_code` string COMMENT '删除网点code',
  `delete_site_name` string COMMENT '删除网点名称',
  `delete_user_code` string COMMENT '删除人code',
  `delete_user_name` string COMMENT '删除人name',
  `scan_site_id` bigint COMMENT '扫描网点id',
  `scan_site_code` string COMMENT '扫描网点code',
  `scan_site_name` string COMMENT '扫描网点名称',
  `scan_user_code` string COMMENT '扫描人code',
  `scan_user_name` string COMMENT '扫描人名称',
  `device_id` string COMMENT '设备号',
  `source` string COMMENT '来源',
  `remark` string COMMENT '备注',
  `create_time` timestamp COMMENT '创建时间')
COMMENT '操作扫描删除表'
PARTITIONED BY (
  `dt` string COMMENT '分区日期')
STORED AS parquet
LOCATION
  '/dw/hive/jms_dwd.db/external/dwd_tab_barscan_scan_delete_base_dt' ;